/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package cassandrawindow;
import java.text.ParseException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Set;

public class HandleDataTableCampIp {
  public static final String KEYSPACE                               =   "AdsData";
    public static final String ColumFamly                           =   "BannerViewCountCf";
    public static final String ColumFamlyBannerClickCountCf         =   "BannerClickCountCf";
    public static final String ColumFamlyBannerViewCountCf          =   "BannerViewCountCf";

    public static final String ColumFamlyCampaignClickCountCf       =   "CampaignCountCf";
    public static final String ColumFamlyCampaignViewCountCf        =   "CampaignViewCountCf";

    public static final String ColumFamlyCampaignIPCountCf          =   "CampaignIpCountCf";
    public void handleData() throws ParseException, InterruptedException
    {
        long first_time = System.currentTimeMillis();
        CassandraAction cassAct = new CassandraAction(ACCOUNT.CLUSTERNAME ,ACCOUNT.URL, ACCOUNT.PORT);
        cassAct.initReadWirte(KEYSPACE);
        MysqlDataManager mysqldatamanager = new MysqlDataManager();
        //CqlDataManager cqldatamanager = new CqlDataManager();
        //String currentDate = TimeUtil.getCurrentTimeInString();
        String currentDate = "2012-07-24";
        cassAct.getIpByCampaign(currentDate, ColumFamlyCampaignIPCountCf, mysqldatamanager);
        Debug.println("success campaignIp");
    }

}
